package com.aizuda.boot.modules.common.constant.enums;


import com.aizuda.core.api.IErrorCode;

/**
 * 响应常量
 *
 * @author duanyao
 */
public enum ResponseCodeEnum implements IErrorCode {

    /**
     * 通用状态码
     */
    DEFAULT_EXCEPTION(-1, "网络开小差啦"),
    PARAM_BINDING_EXCEPTION(-2, "请检查请求参数"),
    BUSINESS_EXCEPTION(-3, "业务异常"),
    OPTIMISTIC_LOCKER_EXCEPTION(-11, "系统繁忙,请稍后重试"),
    SYS_ERROR(-9, "系统内部错误"),
    EXPIRED_TOKEN(-12, "登录过期"),
    NOT_LOGGED(-13, "未登录"),
    USER_DOES_NOT_EXIST(-14, "用户不存在"),
    USER_PASSWORD_ERROR(-15, "用户密码错误"),
    RPC_EXCEPTION(-16, "服务不可用"),
    SERVICE_LIMIT(-17, "服务限流"),
    SUCCESS(500200, "成功"),
    ERROR(500500, "服务端错误"),
    PARAMETER_ERROR(444, "参数错误"),
    SHOW_MSG(60001412, "直接显示错误消息"),
    SAVE_DOC_ERROR(600600, "保存文档出错"),
    DOC_NOT_EXIST(600601, "该文档不存在"),
    SCRAP_DOCUMENT_ERROR(600602, "设置文档（放入/还原）废纸篓出错"),
    MOVE_DOCUMENT_ERROR(600603, "移动文档出错"),
    DELETE_DOCUMENT_ERROR(600604, "删除文档出错"),
    RENAME_DOCUMENT_ERROR(600605, "重命名文档出错"),
    EMPTY_WASTE_BASKET_ERROR(600606, "清空废纸篓出错"),
    REPLACE_COVER_ERROR(600607, "更换封面出错"),
    SAVE_DATA_ERROR(600608, "保存数据不存在"),
    ORDER_NO_NOT_EXIST(-600609, "订单不存在"),
    ORDER_NO_SAVE_FAIL(-600610, "订单提交失败"),
    HAVE_ON_PAID_ORDER(-600611, "有未支付订单，请先进行支付"),
    FILE_TYPE_IS_NOT_SAME(-600612, "传入文件类型与当前文档不一致"),
    DAY_TIMES_IS_OVER(-700001, "注册用户当天查询次数已达到上限"),
    MINUTE_TIMES_IS_OVER(-700002, "注册用户每分钟查询次数已达到上限"),
    COMMIT_LOCKER_EXCEPTION(-700003, "提交频繁,请稍后重试"),
    DAY_TIMES_IS_OVER_VIP(-700004, "会员用户当天查询次数已达到上限"),
    MINUTE_TIMES_IS_OVER_VIP(-700005, "会员用户每分钟查询次数已达到上限"),
    IS_BUY_TY_CARD(-700006, "已购买过新人体验月卡"),
    ALREADY_IN_COLLECT(-700007, "该记录已放入收藏夹！"),
    CHAT_NOT_EXIST(-700008, "未找到该聊天记录！"),
    CRAWLER_URL_ERROR(-700009, "根据url抓取网页内容异常！"),
    UPLOAD_FILE_ERROR(-700010, "上传文件异常！"),
    SUMMARY_ERROR(-700011, "根据URI生成摘要异常！"),
    ANSWER_ERROR(-700012, "根据URI问答异常！"),
    TAGS_ERROR(-700013, "根据URI获取tags异常！"),
    OUTLINES_ERROR(-700014, "根据URI获取outlines异常！"),
    QUESTIONS_ERROR(-700015, "根据URI获取questions异常！"),
    IMAGE_ALREADY_IN_COLLECT(-7000016, "该绘画已放入收藏夹！"),
    INSTRUCTION_ALREADY_IN_COLLECT(-7000017, "该指令已放入收藏夹！"),
    MODIFY_DOCUMENT_APPROVAL_STATUS_ERROR(600611, "修改文档审批状态"),
    FOLDER_NOT_EXIST(600612, "上级文件夹不存在"),
    NOT_YOUR_STUDENT(600613, "只能查看自己学生的文档"),
    FOLDER_IS_EXIST(600614, "文件夹名称已存在"),
    SAVE_DOC_COMMENT_ERROR(600615, "保存文档批注出错"),
    DOC_COMMENT_NOT_EXIST(600616, "该文档批注不存在"),
    EDIT_DOC_COMMENT_ERROR(600617, "编辑文档批注出错"),
    DELETE_DOC_COMMENT_ERROR(600618, "删除文档批注出错"),
    SET_DOC_COMMENT_READ_ERROR(600631, "批量设置批注已读出错"),
    DOC_SHARE_IS_OPEN(600619, "该文档已开启分享，请勿重复操作"),
    DOC_SHARE_IS_NOT_OPEN(600620, "该文档暂未开启分享"),
    DOC_SHARE_IS_CLOSE(600621, "该文档分享链接已失效"),
    CHAT_DATA_IS_SAVE(600622, "该聊天记录已保存，请勿重复操作"),
    CHAT_NOT_IN_COLLECT(-600623, "您还未收藏该记录，请先进行收藏！"),
    DOC_SHARE_NOT_EXIST(600624, "文档分享链接不存在"),
    DOC_NOT_PUBLISH(600625, "该文档暂未发布，请先发布在进行分享"),
    DOC_TAG_IS_EXIST(600626, "该文档标签已存在"),
    DOC_TAG_IS_NOT_EXIST(600627, "该文档标签不存在"),
    HTML_SWITCH_PDF_ERROR(600628, "转换失败，请检查传入参数"),
    OPEN_DOC_ERROR(600629, "开启分享失败，请先在个人中心绑定手机号"),
    IMAGE_CHANGE_ERROR(600630, "图片转换失败"),
    IMAGE_NOT_IN_COLLECT(-600631, "您还未收藏该绘画，请先进行收藏！"),
    CARD_PWD_NOT_EXIST(-600632, "该卡密不存在"),
    CARD_PWD_IS_USED(-600633, "该卡密已使用，请勿重复操作"),
    HAVE_NO_PERMISSION(-600634, "暂无权限"),
    INSTRUCTION_AND_RESULT_NOT_IN_COLLECT(-600635, "您还未收藏该指令和输入输出结果，请先进行收藏！"),
    INSTRUCTION_IS_NOT_EXIST(-60036, "该指令不存在"),
    DATA_NOT_FOUND(-600636, "数据不存在"),
    OPERATION_NOT_ALLOWED(-600637, "操作不允许"),
    DATA_ALREADY_EXISTS(-600638, "数据已存在"),
    THE_DATA_HAS_BEEN_SET(-600639, "数据已经设置,请勿重新设置"),
    FILE_EMPTY(-600640, "上传文件为空"),
    SERVER_ERROR(300302, "代理接口异常"),
    NOT_FOUND_FLOW(600630,"流程不存在" );



    ResponseCodeEnum(long code, String msg) {
        this.code = code;
        this.msg = msg;
    }

    final long code;
    final String msg;

    public long getCode() {
        return code;
    }

    public String getMsg() {
        return msg;
    }
}
